package com.baizhi.springboot.entity;

import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

public class Income {
    /* `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` varchar(255) DEFAULT NULL,
  `department` varchar(255) DEFAULT NULL,
  `date` datetime DEFAULT NULL,
  `post` varchar(255) DEFAULT NULL,
  `thing` varchar(255) DEFAULT NULL,
  `approver` varchar(255) DEFAULT NULL,*/
    private Integer id;
    private String name;
    private String department;
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date date;
    private String post;
    private String thing;
    private String approver;

    @Override
    public String toString() {
        return "Income{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", department='" + department + '\'' +
                ", date=" + date +
                ", post='" + post + '\'' +
                ", thing='" + thing + '\'' +
                ", approver='" + approver + '\'' +
                '}';
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDepartment() {
        return department;
    }

    public void setDepartment(String department) {
        this.department = department;
    }

    public Date getDate() {
        return date;
    }

    public void setDate(Date date) {
        this.date = date;
    }

    public String getPost() {
        return post;
    }

    public void setPost(String post) {
        this.post = post;
    }

    public String getThing() {
        return thing;
    }

    public void setThing(String thing) {
        this.thing = thing;
    }

    public String getApprover() {
        return approver;
    }

    public void setApprover(String approver) {
        this.approver = approver;
    }

    public Income() {
    }

    public Income(Integer id, String name, String department, Date date, String post, String thing, String approver) {
        this.id = id;
        this.name = name;
        this.department = department;
        this.date = date;
        this.post = post;
        this.thing = thing;
        this.approver = approver;
    }
}
